package com.studentgrowth.repository;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.studentgrowth.model.learning.LearningPlan;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;

@Mapper
public interface LearningPlanRepository extends BaseMapper<LearningPlan> {
    // 使用MyBatis-Plus的BaseMapper替代JPA的JpaRepository
    // BaseMapper已经提供了基础的CRUD方法
    
    // 如果需要自定义查询方法：
    default List<LearningPlan> findByUserId(Long userId) {
        return selectList(new QueryWrapper<LearningPlan>().eq("user_id", userId));
    }
} 